﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Runtime.Serialization;


namespace Modellayer
{
    [DataContract]
    public class Person
    {
        [DataMember]
        public int phoneNumber { get; set; }
        [DataMember]
        public string email { get; set; }
        [DataMember]
        public string password { get; set; }
        [DataMember]
        public string name { get; set; }
        [DataMember]
        public string type { get; set; }
        [DataMember]
        public string loginId { get; set; }

        public Person(int phoneNumber, string password, string name, string t, string lId)
        {
            this.phoneNumber = phoneNumber;
            this.password = password;
            this.name = name;
            this.type = t;
            if(type == "employee")
            {
                loginId = lId;
            }
            else
            {
                loginId = null;
            }

        }
        public Person()
        {

        }


        





    }
}
